<!-- 文件名: app/templates/play_video.html -->
{% extends "base.html" %}

{% block title %}播放视频 - 社交媒体监控{% endblock %}

{% block page_title %}播放视频{% endblock %}

{% block content %}
<div class="mb-3">
    <a href="/videos{% if video.user_id %}?user_id={{ video.user_id }}{% endif %}" class="btn btn-secondary">返回视频列表</a>
    <a href="/users/{{ video.user_id }}" class="btn btn-info">查看用户</a>
</div>

<div class="card mb-4">
    <div class="card-body">
        <h5 class="card-title">{{ video.title }}</h5>
        <p class="card-text">用户: {{ video.username }}</p>
        <p class="card-text">平台: <span class="badge platform-{{ video.platform }}">{{ video.platform }}</span></p>
        <p class="card-text">添加时间: {{ video.created_at }}</p>
        <p class="card-text">下载时间: {{ video.download_at }}</p>
    </div>
</div>

<div class="video-container">
    <video controls class="video-player">
        <source src="{{ video.local_path }}" type="video/mp4">
        您的浏览器不支持视频播放
    </video>
</div>
{% endblock %}